import BScroll from "better-scroll";


/**
 * 
 * @param {*} that 
 * @param {*} wrapper 
 * @param {*} content 
 * @param {*} num 
 * @param {*} itemWidth 
 */
let betterScrollHorizontal = function (that, wrapper, content, num, itemWidth){
    content.style.width = num * itemWidth + "rem";
    that.$nextTick(()=>{
        that.scroll = new BScroll(wrapper,{
            scrollY:false,
            scrollX:true,
            startX:0,
            click:true,
        });
    });
}
export {betterScrollHorizontal};